package zh.dummy.netty.core.protocol;

import java.util.Map;

public class Header {
	private int crcCode = 0xabef0101;//校验码
	private long sessionID;//会话ID
	private byte type;//消息类型
	private byte priority;//消息优先级
	private int attchLength;
	private Map<String,Object> attchment;
	
	
	public int getCrcCode() {
		return crcCode;
	}


	public void setCrcCode(int crcCode) {
		this.crcCode = crcCode;
	}


	public long getSessionID() {
		return sessionID;
	}


	public void setSessionID(long sessionID) {
		this.sessionID = sessionID;
	}


	public byte getType() {
		return type;
	}


	public void setType(byte type) {
		this.type = type;
	}


	public byte getPriority() {
		return priority;
	}


	public void setPriority(byte priority) {
		this.priority = priority;
	}


	@Override
	public String toString() {
		return "Header [crcCode=" + crcCode + ", sessionID=" + sessionID + ", type=" + type
				+ ", priority=" + priority + "]";
	}

	public Map<String,Object> getAttchment() {
		return attchment;
	}


	public void setAttchment(Map<String,Object> attchment) {
		this.attchment = attchment;
	}


	public int getAttchLength() {
		return attchLength;
	}


	public void setAttchLength(int attchLength) {
		this.attchLength = attchLength;
	}
}
